<!DOCTYPE html>
<html  dir="ltr">

    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <title>u-root</title>
        <link rel="shortcut icon" href="images/favicon.ico" type="image/x-icon">
        <link rel="apple-touch-icon-precomposed" href="images/apple-touch-icon.png">
        <!--<link rel="stylesheet" href="/templates/pandoc-uikit/uikit.css">-->
        <!--<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/uikit/2.26.4/css/uikit.gradient.css">-->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/uikit/2.26.4/css/uikit.gradient.min.css">
        <link rel="stylesheet" href="/templates/pandoc-uikit/style.css">
        <link href="https://vjs.zencdn.net/5.4.4/video-js.css" rel="stylesheet" />
        <script src="https://code.jquery.com/jquery-2.2.1.min.js"></script>
        <!--<script src="https://cdnjs.cloudflare.com/ajax/libs/uikit/2.26.4/js/uikit.min.js"></script>-->
        <script src="/templates/pandoc-uikit/uikit.js"></script>
        <script src="/templates/pandoc-uikit/scripts.js"></script>
        <script src="/bower_components/sticky-kit/jquery.sticky-kit.js "></script>

        <meta name="generator" content="pandoc" />
                        <title>u-root</title>
        <style type="text/css">code{white-space: pre;}</style>
                        <style type="text/css">
            pre > code.sourceCode { white-space: pre; position: relative; }
            pre > code.sourceCode > span { display: inline-block; line-height: 1.25; }
            pre > code.sourceCode > span:empty { height: 1.2em; }
            .sourceCode { overflow: visible; }
            code.sourceCode > span { color: inherit; text-decoration: inherit; }
            div.sourceCode { margin: 1em 0; }
            pre.sourceCode { margin: 0; }
            @media screen {
            div.sourceCode { overflow: auto; }
            }
            @media print {
            pre > code.sourceCode { white-space: pre-wrap; }
            pre > code.sourceCode > span { text-indent: -5em; padding-left: 5em; }
            }
            pre.numberSource code
              { counter-reset: source-line 0; }
            pre.numberSource code > span
              { position: relative; left: -4em; counter-increment: source-line; }
            pre.numberSource code > span > a:first-child::before
              { content: counter(source-line);
                position: relative; left: -1em; text-align: right; vertical-align: baseline;
                border: none; display: inline-block;
                -webkit-touch-callout: none; -webkit-user-select: none;
                -khtml-user-select: none; -moz-user-select: none;
                -ms-user-select: none; user-select: none;
                padding: 0 4px; width: 4em;
                color: #aaaaaa;
              }
            pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa;  padding-left: 4px; }
            div.sourceCode
              {   }
            @media screen {
            pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; }
            }
            code span.al { color: #ff0000; font-weight: bold; } /* Alert */
            code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */
            code span.at { color: #7d9029; } /* Attribute */
            code span.bn { color: #40a070; } /* BaseN */
            code span.bu { } /* BuiltIn */
            code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */
            code span.ch { color: #4070a0; } /* Char */
            code span.cn { color: #880000; } /* Constant */
            code span.co { color: #60a0b0; font-style: italic; } /* Comment */
            code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */
            code span.do { color: #ba2121; font-style: italic; } /* Documentation */
            code span.dt { color: #902000; } /* DataType */
            code span.dv { color: #40a070; } /* DecVal */
            code span.er { color: #ff0000; font-weight: bold; } /* Error */
            code span.ex { } /* Extension */
            code span.fl { color: #40a070; } /* Float */
            code span.fu { color: #06287e; } /* Function */
            code span.im { } /* Import */
            code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */
            code span.kw { color: #007020; font-weight: bold; } /* Keyword */
            code span.op { color: #666666; } /* Operator */
            code span.ot { color: #007020; } /* Other */
            code span.pp { color: #bc7a00; } /* Preprocessor */
            code span.sc { color: #4070a0; } /* SpecialChar */
            code span.ss { color: #bb6688; } /* SpecialString */
            code span.st { color: #4070a0; } /* String */
            code span.va { color: #19177c; } /* Variable */
            code span.vs { color: #4070a0; } /* VerbatimString */
            code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */
        </style>
        <style>.kommentar {display: none;}</style>
                                               
    </head>

    <body>


        <div class="uk-container uk-container-center uk-margin-top uk-margin-large-bottom">

                        <div class="uk-grid" data-uk-grid-margin>
                <div class="uk-width-1-1">
                    <h1 class="uk-heading-large">u-root</h1>
                                                        </div>
            </div>
            
            <div class="uk-grid" data-uk-grid-margin >          
                <div class="uk-width-medium-1-4">
                    <div class="uk-overflow-container" data-uk-sticky="{top:25,media: 768}">
                        <div class="uk-panel uk-panel-box menu-begin" >

                                                        <ul>
                                                        <li><a href="#u-root">u-root</a>
                                                        <ul>
                                                        <li><a href="#setup">Setup</a></li>
                                                        <li><a href="#submitting-changes">Submitting Changes</a></li>
                                                        <li><a href="#faqs">FAQs</a>
                                                        <ul>
                                                        <li><a href="#so-why-u-root">So, why “u-root”?</a></li>
                                                        <li><a href="#any-publications">Any publications?</a></li>
                                                        </ul></li>
                                                        <li><a href="#community">Community</a></li>
                                                        <li><a href="#contributors">Contributors</a></li>
                                                        <li><a href="#logo">Logo</a></li>
                                                        </ul></li>
                                                        </ul>
                            
                        </div>
                    </div>
                </div>

                <div class="uk-width-medium-3-4">
<p><img src="img/u-root-logo.png" width="300" alt="u-root logo" /><br />
</p>
<h1 id="u-root">u-root</h1>
<p>u-root embodies four different projects.</p>
<ul>
<li><p>Go versions of many standard Linux tools, such as <a href="https://github.com/u-root/u-root/tree/master/cmds/core/ls/ls.go">ls</a>, <a href="https://github.com/u-root/u-root/tree/master/cmds/core/cp/cp.go">cp</a>, or <a href="https://github.com/u-root/u-root/tree/master/cmds/core/shutdown/shutdown.go">shutdown</a>. See <a href="https://github.com/u-root/u-root/tree/master/cmds/core">cmds/core</a> for most of these.</p></li>
<li><p>A way to compile many Go programs into a single binary with <a href="https://github.com/u-root/u-root/tree/master/pkg/bb/README.md">busybox mode</a>.</p></li>
<li><p>A way to create initramfs (an archive of files) to use with Linux kernels.</p></li>
<li><p>Go bootloaders that use <code>kexec</code> to boot Linux or multiboot kernels such as ESXi, Xen, or tboot. They are meant to be used with <a href="https://www.linuxboot.org">LinuxBoot</a>. With that, parsers for <a href="https://github.com/u-root/u-root/tree/master/pkg/boot/grub">GRUB config files</a> or <a href="https://github.com/u-root/u-root/tree/master/pkg/boot/syslinux">syslinux config files</a> are to make transition to LinuxBoot easier.</p></li>
</ul>
<h2 id="setup">Setup</h2>
<p>On an Ubuntu system, install prerequisites and ensure Go is at least version 1.13:</p>
<div class="sourceCode" id="cb1"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb1-1"><a href="#cb1-1" aria-hidden="true" tabindex="-1"></a><span class="fu">sudo</span> apt-get install git golang build-essential</span>
<span id="cb1-2"><a href="#cb1-2" aria-hidden="true" tabindex="-1"></a><span class="ex">go</span> version</span></code></pre></div>
<p>Set your <code>GOPATH</code>:</p>
<div class="sourceCode" id="cb2"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb2-1"><a href="#cb2-1" aria-hidden="true" tabindex="-1"></a><span class="bu">export</span> <span class="va">GOPATH=</span><span class="st">&quot;</span><span class="va">$HOME</span><span class="st">/go&quot;</span></span></code></pre></div>
<p>Clone u-root:</p>
<div class="sourceCode" id="cb3"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb3-1"><a href="#cb3-1" aria-hidden="true" tabindex="-1"></a><span class="ex">go</span> get github.com/u-root/u-root</span></code></pre></div>
<p>Generate an initramfs containing u-root Go tools:</p>
<div class="sourceCode" id="cb4"><pre class="sourceCode sh"><code class="sourceCode bash"><span id="cb4-1"><a href="#cb4-1" aria-hidden="true" tabindex="-1"></a><span class="ex">u-root</span> <span class="at">-format</span><span class="op">=</span>cpio <span class="at">-o</span> initramfs.cpio</span></code></pre></div>
<p>You can use this initramfs with your favorite Linux kernel in QEMU to try it out.</p>
<p>More instructions can be found in the repo’s <a href="https://github.com/u-root/u-root/blob/master/README.md">README.md</a>.</p>
<h2 id="submitting-changes">Submitting Changes</h2>
<p>We use <a href="https://github.com/u-root/u-root/pulls">GitHub Pull Requests</a> for code review. Pull requests must receive one approval and pass CI before being merged.</p>
<h2 id="faqs">FAQs</h2>
<h3 id="so-why-u-root">So, why “u-root”?</h3>
<p>It’s to reflect a universal root, you can mount on every local and get a userland portable (it’s a goal).</p>
<h3 id="any-publications">Any publications?</h3>
<ul>
<li><a href="https://www.usenix.org/system/files/conference/atc15/atc15-paper-minnich.pdf">USENIX 2015 ATC Paper</a></li>
<li><a href="https://www.usenix.org/conference/atc15/technical-session/presentation/minnich">USENIX 2015 ATC Talk</a></li>
<li>Related: Embedded Linux Conference 2017 LinuxBoot Talk (<a href="https://www.youtube.com/watch?v=iffTJ1vPCSo">YouTube video</a>, <a href="https://schd.ws/hosted_files/osseu17/84/Replace%20UEFI%20with%20Linux.pdf">slides</a>)</li>
</ul>
<h2 id="community">Community</h2>
<ul>
<li><a href="https://groups.google.com/forum/#!forum/u-root">Join the mailing list</a></li>
<li><a href="https://osfw.slack.com/">Join the Open Source Firmware Slack team</a> (Get an invite <a href="https://slack.osfw.dev">here</a>.)</li>
<li><a href="https://github.com/u-root/u-root/blob/master/roadmap.md">Checkout the roadmap</a></li>
</ul>
<h2 id="contributors">Contributors</h2>
<ul>
<li><a href="https://github.com/rminnich">Ron Minnich</a></li>
<li><a href="https://github.com/mirtchovski">Andrey Mirtchovski</a></li>
<li><a href="https://github.com/rhiguita">Alexandre Beletti</a></li>
<li><a href="https://github.com/ryukinix">Manoel Machado</a></li>
<li><a href="https://github.com/rafaelcn">Rafael C. Nunes</a></li>
<li><a href="https://github.com/mathgamain">Matheus Pinto Rodrigues</a></li>
<li><a href="https://github.com/GanShun">Gan Shun Lim</a></li>
<li><a href="https://github.com/rjoleary">Ryan O’Leary</a></li>
<li><a href="https://github.com/hugelgupf">Chris Koch</a></li>
<li><a href="https://github.com/insomniacslk">Andrea Barberio</a></li>
<li><a href="https://github.com/vejmarie">Jean-Marie Verdun</a></li>
<li><a href="https://github.com/n-canter">Max Shegai</a></li>
</ul>
<h2 id="logo">Logo</h2>
<p>The Go gopher was designed by Renee French. The u-root logo design is licensed under the Creative Commons 3.0 Attributions license.</p>
<p>The logo is communicating several things:</p>
<ul>
<li><p>u-root has several flavors: firmware and as a root file system</p></li>
<li><p>the gopher at the bottom is a firmware u-root; that gopher brings the machine up, hence the wrench. Its work is also done, so it is resting.</p></li>
<li><p>the other gophers can make more copies of u-root; hence the u-root logo on their chest.</p></li>
<li><p>the highest gopher is showing how u-root is a good root file system for a VM.</p></li>
<li><p>the U itself is a stylized tree, evocative of roots.</p></li>
</ul>                    
                </div>
            </div>

  </script>
            <script src="https://vjs.zencdn.net/5.4.4/video.js"></script>
        </div>
    </body>
</html>
